USE [Veteran_cms]
GO

/****** Object:  Table [dbo].[multimedia_file]    Script Date: 09/08/2012 11:09:41 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

ALTER TABLE [dbo].[multimedia_file](
	[file_id] [int] IDENTITY(1,1) NOT NULL,
	[category_id] [int] NULL,
	[title] [nvarchar](255) NULL,
	[slug] [nvarchar](255) NULL,
	[description] [ntext] NULL,
	[content] [ntext] NULL,
	[image_square] [ntext] NULL,
	[image_thumbnail] [ntext] NULL,
	[image_small] [ntext] NULL,
	[image_crop] [ntext] NULL,
	[image_medium] [ntext] NULL,
	[image_large] [ntext] NULL,
	[image_original] [ntext] NULL,
	[num_views] [int] NULL,
	[created_date] [datetime] NOT NULL,
	[created_user] [int] NULL,
	[created_user_name] [nvarchar](255) NULL,
	[allow_comment] [bit] NULL,
	[ordering] [int] NULL,
	[num_comments] [int] NULL,
	[url] [nvarchar](255) NULL,
	[html_code] [ntext] NULL,
	[is_active] [bit] NOT NULL,
	[file_type] [nchar](5) NULL,
 CONSTRAINT [PK__multimedia_file__49C3F6B7] PRIMARY KEY CLUSTERED 
(
	[file_id] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]

GO

ALTER TABLE [dbo].[multimedia_file]  WITH CHECK ADD  CONSTRAINT [CK__multimedi__file___4F7CD00D] CHECK  (([file_type]='game' OR [file_type]='audio' OR [file_type]='video' OR [file_type]='image'))
GO

ALTER TABLE [dbo].[multimedia_file] CHECK CONSTRAINT [CK__multimedi__file___4F7CD00D]
GO

ALTER TABLE [dbo].[multimedia_file] ADD  CONSTRAINT [DF__multimedi__num_v__4AB81AF0]  DEFAULT ((0)) FOR [num_views]
GO

ALTER TABLE [dbo].[multimedia_file] ADD  CONSTRAINT [DF__multimedi__allow__4BAC3F29]  DEFAULT ((1)) FOR [allow_comment]
GO

ALTER TABLE [dbo].[multimedia_file] ADD  CONSTRAINT [DF__multimedi__order__4CA06362]  DEFAULT ((0)) FOR [ordering]
GO

ALTER TABLE [dbo].[multimedia_file] ADD  CONSTRAINT [DF__multimedi__num_c__4D94879B]  DEFAULT ((0)) FOR [num_comments]
GO

ALTER TABLE [dbo].[multimedia_file] ADD  CONSTRAINT [DF__multimedi__is_ac__4E88ABD4]  DEFAULT ((1)) FOR [is_active]
GO

ALTER TABLE [dbo].[multimedia_file] ADD  CONSTRAINT [DF__multimedi__file___5070F446]  DEFAULT ('image') FOR [file_type]
GO


